Termination w.r.t. Q of the following Term Rewriting System could be proven:

Q restricted rewrite system:
The TRS R consists of the following rules:

f(j(x, y), y) → g(f(x, k(y)))
f(x, h1(y, z)) → h2(0, x, h1(y, z))
g(h2(x, y, h1(z, u))) → h2(s(x), y, h1(z, u))
h2(x, j(y, h1(z, u)), h1(z, u)) → h2(s(x), y, h1(s(z), u))
i(f(x, h(y))) → y
i(h2(s(x), y, h1(x, z))) → z
k(h(x)) → h1(0, x)
k(h1(x, y)) → h1(s(x), y)

Q is empty.


QTRS
  ↳ DirectTerminationProof

Q restricted rewrite system:
The TRS R consists of the following rules:

f(j(x, y), y) → g(f(x, k(y)))
f(x, h1(y, z)) → h2(0, x, h1(y, z))
g(h2(x, y, h1(z, u))) → h2(s(x), y, h1(z, u))
h2(x, j(y, h1(z, u)), h1(z, u)) → h2(s(x), y, h1(s(z), u))
i(f(x, h(y))) → y
i(h2(s(x), y, h1(x, z))) → z
k(h(x)) → h1(0, x)
k(h1(x, y)) → h1(s(x), y)

Q is empty.

We use [23] with the following order to prove termination.

Lexicographic path order with status [19].
Precedence:
j2 > f2 > h12 > h23 > s1 > 0
j2 > g1 > h12 > h23 > s1 > 0
j2 > k1 > h12 > h23 > s1 > 0
i1 > 0
h1 > h12 > h23 > s1 > 0

Status:
h1: multiset
j2: multiset
i1: multiset
k1: multiset
h23: [2,1,3]
f2: [1,2]
h12: [1,2]
0: multiset
s1: multiset
g1: multiset